package com.cgc.venus.server.core.k8s.inter;

import com.cgc.venus.server.core.exception.VenusException;
import io.fabric8.kubernetes.api.model.Node;
import io.fabric8.kubernetes.api.model.NodeList;
import io.fabric8.kubernetes.api.model.Pod;

import java.util.List;
import java.util.Map;

/**
 * Created by xiaobin on 2017/9/19.
 */
public interface K8sNodeService {
    /*
*查询节点信息
 */
    public List<Node> nodeDataQuery() throws VenusException;
    /*
    设置node标签
     */
    public boolean nodeLabelSet(String nodeName,Map<String,String> lables) throws VenusException;

    /*
   获取物理分组的node标签
     */
    public List<String> nodeLabel() throws VenusException;

    /*
*查询k8s标签下的节点信息
*/
    public NodeList nodeQueryByLabel(String label) throws VenusException;

    public List<Pod> getPods() throws VenusException;
    /*
    *查询k8s的某个节点下pod数量
    */
    public int podNumber(String nodeName) throws VenusException;
}
